<%--
  Created by IntelliJ IDEA.
  User: ASUS
  Date: 2021/8/16
  Time: 9:05
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
    <title>-账号管理-</title>
    <meta name="renderer" content="webkit">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
    <meta name="apple-mobile-web-app-status-bar-style" content="black">
    <meta name="apple-mobile-web-app-capable" content="yes">
    <meta name="format-detection" content="telephone=no">

    <link rel="stylesheet" href="../layui/css/layui.css" media="all">
    <script src="../layui/layui.js"></script>
    <script src="../js/jquery-3.1.0.js"></script>

    <style>
        body {
            background-color: #eeeeee;
        }

        .layui-row {
            background-color: white;
            margin: 10px;
            padding: 10px;
        }

        select {
            border: 0.5px solid #eeeeee;
        }

    </style>
</head>
<body>
<div class="layui-layout layui-layout-admin">


    <%--面包屑--%>
    <div class="layui-row">
        <div class="layui-col-lg12">

                <span class="layui-breadcrumb">
                  <a href="http://localhost/admin/admin.jsp">首页</a>
                    <a class="" href="javascript:;">系统设置</a>
                    <a href="http://localhost/admin/account.jsp">账号管理</a>
                </span>
        </div>
    </div>

    <%--顶部搜索栏--%>
    <div class="layui-row">
        <div class="layui-col-lg3" style="font-size: 16px;">
            <div class="layui-form-item">
                <label class="layui-form-label">关键词：</label>
                <div class="layui-input-inline">
                    <input type="text" name="keyword" placeholder="工号/学号" class="layui-input">
                </div>
            </div>
        </div>
        <div class="layui-col-lg2">
            <button type="button" class="layui-btn" data-type="reload"><i class="layui-icon layui-icon-search"
                                                                          style="font-size: 20px; color: white;"></i>搜索
            </button>
        </div>
    </div>

    <%--中部操作栏--%>
    <div class="layui-row">
        <button type="button" class="layui-btn" id="account-add-btn">新增</button>
        <button type="button" class="layui-btn" id="account-tadds-btn">批量导入信息</button>
    </div>

    <%--数据表格-选项卡样式--%>
    <div class="layui-row">
        <div class="layui-tab layui-tab-card">
            <ul class="layui-tab-title">
                <li class="layui-this">教师信息</li>
                <li>学生信息</li>
            </ul>
            <div class="layui-tab-content" style="height: 700px;">
                <div class="layui-tab-item layui-show">
                    <table id="account-teacher-table" lay-filter="account-teacher-table"></table>
                </div>
                <div class="layui-tab-item">
                    <table id="account-student-table" lay-filter="account-student-table"></table>
                </div>
            </div>
        </div>
    </div>


</div>
</body>
<%--表内状态栏--%>
<div id="switchStatus" style="display: none;">
    <input type="checkbox" name="close" lay-skin="switch" lay-text="启用|禁用">
</div>
<%--表内工具栏--%>
<script type="text/html" id="accountBtn">
    <a class="layui-btn layui-btn-normal layui-btn-xs" lay-event="query"><i
            class="layui-icon layui-icon-query"></i>查看</a>
    <a class="layui-btn layui-btn-normal layui-btn-xs" lay-event="edit"><i class="layui-icon layui-icon-edit"></i>编辑</a>
    <a class="layui-btn layui-btn-danger layui-btn-xs" lay-event="del"><i
            class="layui-icon layui-icon-delete"></i>删除</a>
</script>
<%--弹出层--新增页面--%>
<div class="layui-row" id="account-add-box" style="margin: 20px;display: none">
    <div class="layui-tab layui-tab-card">
        <ul class="layui-tab-title">
            <li class="layui-this">新增教师</li>
            <li>新增学生</li>
        </ul>
        <div class="layui-tab-content" style="height: 540px;">
            <%--新增教师页面--%>
            <div class="layui-tab-item layui-show">
                <form class="layui-form" id="account-teacher-add" action="" autocomplete="off"
                      lay-filter="component-form-group">
                    <div class="layui-form-item">
                        <label class="layui-form-label">工号：</label>
                        <div class="layui-input-block"><input type="text" name="tNO" lay-verify="tNO"
                                                              class="layui-input"></div>
                    </div>
                    <div class="layui-form-item">
                        <label class="layui-form-label">密码：</label>
                        <div class="layui-input-block"><input type="text" name="password" lay-verify="password"
                                                              class="layui-input"></div>
                    </div>
                    <div class="layui-form-item">
                        <label class="layui-form-label">真实姓名：</label>
                        <div class="layui-input-block"><input type="text" name="name" lay-verify="name"
                                                              class="layui-input"></div>
                    </div>
                    <div class="layui-form-item">
                        <label class="layui-form-label">性别：</label>
                        <div class="layui-input-block">
                            <input type="radio" name="sex" value="男" title="男" checked>
                            <input type="radio" name="sex" value="女" title="女">
                        </div>
                    </div>
                    <div class="layui-form-item">
                        <label class="layui-form-label">学院编号：</label>
                        <div class="layui-input-block"><select name="collegeId" lay-verify="college"
                                                               style="width: 140px;height: 40px;">
                            <option value="">请选择学院</option>
                            <option value="1">测试学院</option>
                            <option value="2">学院2</option>
                            <option value="3">学院3</option>
                            <option value="4">学院4</option>
                            <option value="5">学院5</option>
                        </select></div>
                    </div>
                    <div class="layui-form-item">
                        <label class="layui-form-label">部门：</label>
                        <div class="layui-input-block"><input type="text" name="department" lay-verify="department"
                                                              class="layui-input"></div>
                    </div>
                    <div class="layui-form-item">
                        <label class="layui-form-label">职位：</label>
                        <div class="layui-input-block"><input type="text" name="post" lay-verify="post"
                                                              class="layui-input"></div>
                    </div>
                    <div class="layui-form-item">
                        <label class="layui-form-label">联系方式：</label>
                        <div class="layui-input-block"><input type="text" name="tel" lay-verify="tel"
                                                              class="layui-input"></div>
                    </div>
                    <div class="layui-form-item">
                        <label class="layui-form-label">邮箱：</label>
                        <div class="layui-input-block"><input type="text" name="email" lay-verify="email"
                                                              class="layui-input"></div>
                    </div>
                    <div class="layui-col-lg2 layui-col-lg-offset5">
                        <button class="layui-btn" name="account-add-btn1" lay-submit lay-filter="tAdd">添加</button>
                    </div>
                </form>
            </div>
            <%--新增学生页面--%>
            <div class="layui-tab-item">
                <form class="layui-form" id="account-student-add" action="" lay-filter="component-form-group">
                    <div class="layui-form-item">
                        <label class="layui-form-label">学号：</label>
                        <div class="layui-input-block"><input type="text" name="sNO" lay-verify="sNO"
                                                              class="layui-input"></div>
                    </div>
                    <div class="layui-form-item">
                        <label class="layui-form-label">密码：</label>
                        <div class="layui-input-block"><input type="text" name="password" lay-verify="password"
                                                              class="layui-input"></div>
                    </div>
                    <div class="layui-form-item">
                        <label class="layui-form-label">真实姓名：</label>
                        <div class="layui-input-block"><input type="text" name="name" lay-verify="name"
                                                              class="layui-input"></div>
                    </div>
                    <div class="layui-form-item">
                        <label class="layui-form-label">性别：</label>
                        <div class="layui-input-block">
                            <input type="radio" name="sex" value="男" title="男" checked>
                            <input type="radio" name="sex" value="女" title="女">
                        </div>
                    </div>
                    <div class="layui-form-item">
                        <label class="layui-form-label">学院：</label>
                        <div class="layui-input-block"><select name="collName" lay-verify="college"
                                                               style="width: 140px;height: 40px;">
                            <option value="">请选择学院</option>
                            <option value="测试学院">测试学院</option>
                            <option value="学院2">学院2</option>
                            <option value="学院3">学院3</option>
                            <option value="学院4">学院4</option>
                            <option value="学院5">学院5</option>
                        </select></div>
                    </div>
                    <div class="layui-form-item">
                        <label class="layui-form-label">专业：</label>
                        <div class="layui-input-block"><input type="text" name="majorName" lay-verify="major"
                                                              class="layui-input"></div>
                    </div>
                    <div class="layui-form-item">
                        <label class="layui-form-label">班级：</label>
                        <div class="layui-input-block"><input type="text" name="classes" lay-verify="classes"
                                                              class="layui-input"></div>
                    </div>
                    <div class="layui-form-item">
                        <label class="layui-form-label">联系方式：</label>
                        <div class="layui-input-block"><input type="text" name="tel" lay-verify="tel"
                                                              class="layui-input"></div>
                    </div>
                    <div class="layui-form-item">
                        <label class="layui-form-label">邮箱：</label>
                        <div class="layui-input-block"><input type="text" name="email" lay-verify="email"
                                                              class="layui-input"></div>
                    </div>
                    <div class="layui-col-lg2 layui-col-lg-offset5">
                        <button class="layui-btn" name="account-add-btn2" lay-submit lay-filter="sAdd">添加</button>
                    </div>
                </form>
            </div>
        </div>
    </div>
</div>
<%--弹出层--批量导入页面--教师--%>
<div class="layui-row" id="account-tadds-box" style="margin: 20px;width:700px;height:200px;display: none">
    <div class="layui-form-item">
        <label class="layui-form-label">下载导入模板：</label>
        <div class="layui-btn-container">
            <a href="${pageContext.request.contextPath}/downloadFile?filename=老师批量导入模板.xls&url=template"
               class="layui-btn ">
                <i class="layui-icon layui-icon-template-1"></i>老师导入模板</a>
            <a href="${pageContext.request.contextPath}/downloadFile?filename=学生批量导入模板.xls&url=template"
               class="layui-btn ">
                <i class="layui-icon layui-icon-template-1"></i>学生导入模板
            </a>
        </div>
    </div>
    <div class="layui-form-item">
        <label class="layui-form-label">批量导入老师信息：</label>
        <div class="layui-btn-container">
            <button type="button" class="layui-btn layui-btn-normal" id="account-tfile-choose">
                <i class="layui-icon  layui-icon-link"></i>选择文件
            </button>
            <button type="button" class="layui-btn layui-btn-danger" id="account-tfile-upload">
                <i class="layui-icon layui-icon-upload"></i>开始上传
            </button>
        </div>
    </div>

    <div class="layui-form-item">
        <label class="layui-form-label">批量导入学生信息</label>
        <div class="layui-btn-container">
            <button type="button" class="layui-btn layui-btn-normal" id="account-sfile-choose">
                <i class="layui-icon layui-icon-link"></i>选择文件
            </button>
            <button type="button" class="layui-btn layui-btn-danger" id="account-sfile-upload">
                <i class="layui-icon layui-icon-upload"></i>开始上传
            </button>
        </div>
    </div>

</div>


<%--弹出层--查看页面--教师数据展示--%>
<div class="layui-row" id="account-showTeacher-box" style="display: none">
    <table class="layui-table" lay-skin="line">
        <thead>
        <tr>
            <td colspan="4"><h2>详情</h2></td>
        </tr>
        </thead>
        <tbody>
        <tr>
            <td class="left">工号:</td>
            <td class="right" id="Tshow-TNO"></td>
            <td class="left">密码:</td>
            <td class="right" id="Tshow-password"></td>
        </tr>
        <tr>
            <td class="left">真实姓名:</td>
            <td class="right" id="Tshow-name"></td>
            <td class="left">性别:</td>
            <td class="right" id="Tshow-sex"></td>
        </tr>
        <tr>
            <td class="left">学院编号:</td>
            <td class="right" id="Tshow-collegeId"></td>
            <td class="left">部门:</td>
            <td class="right" id="Tshow-department"></td>

        </tr>
        <tr>
            <td class="left">职位:</td>
            <td class="right" id="Tshow-post"></td>
            <td class="left">角色:</td>
            <td class="right" id="Tshow-role"></td>
        </tr>
        <tr>
            <td class="left">联系方式:</td>
            <td class="right" id="Tshow-tel"></td>
            <td class="left">邮箱:</td>
            <td class="right" id="Tshow-email"></td>
        </tr>
        <tr>
            <td class="left">状态:</td>
            <td class="right" id="Tshow-status"></td>
        </tr>
        </tbody>
    </table>
</div>
<%--弹出层--查看页面--学生数据展示--%>
<div class="layui-row" id="account-showStudent-box" style="display: none">
    <table class="layui-table" lay-skin="line">
        <thead>
        <tr>
            <td colspan="4"><h2>详情</h2></td>
        </tr>
        </thead>
        <tbody>
        <tr>
            <td class="left">学号:</td>
            <td class="right" id="Sshow-SNO"></td>
            <td class="left">密码:</td>
            <td class="right" id="Sshow-password"></td>
        </tr>
        <tr>
            <td class="left">真实姓名:</td>
            <td class="right" id="Sshow-name"></td>
            <td class="left">性别:</td>
            <td class="right" id="Sshow-sex"></td>
        </tr>
        <tr>
            <td class="left">学院:</td>
            <td class="right" id="Sshow-collName"></td>
            <td class="left">专业:</td>
            <td class="right" id="Sshow-majorName"></td>

        </tr>
        <tr>
            <td class="left">班级:</td>
            <td class="right" id="Sshow-classes"></td>
            <td class="left">角色:</td>
            <td class="right" id="Sshow-role"></td>
        </tr>
        <tr>
            <td class="left">联系方式:</td>
            <td class="right" id="Sshow-tel"></td>
            <td class="left">邮箱:</td>
            <td class="right" id="Sshow-email"></td>
        </tr>
        <tr>
            <td class="left">状态:</td>
            <td class="right" id="Sshow-status"></td>
        </tr>
        </tbody>
    </table>
</div>

<%--弹出层--教师编辑页面--%>
<div class="layui-row" id="account-editTeacher-box" style="margin: 20px;width:500px;height:400px;display: none">
    <form class="layui-form" action="" lay-filter="component-form-group" autocomplete="off">
        <div class="layui-form-item">
            <label class="layui-form-label">工号：</label>
            <div class="layui-input-block"><input type="text" name="Tedit_tNO" id="Tedit_tNO" lay-verify="tNO"
                                                  class="layui-input"></div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">密码：</label>
            <div class="layui-input-block"><input type="text" name="Tedit_password" id="Tedit_password"
                                                  lay-verify="password" class="layui-input"></div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">真实姓名：</label>
            <div class="layui-input-block"><input type="text" name="Tedit_name" id="Tedit_name" lay-verify="name"
                                                  class="layui-input">
            </div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">性别：</label>
            <div class="layui-input-block">
                <input type="radio" name="Tedit_sex" value="男" title="男">
                <input type="radio" name="Tedit_sex" value="女" title="女">
            </div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">学院编号：</label>
            <div class="layui-input-block"><select name="Tedit_collegeId" id="Tedit_collegeId"
                                                   style="width: 140px;height: 40px;">
                <option value="1">学院1</option>
                <option value="2">学院2</option>
                <option value="3">学院3</option>
                <option value="4">学院4</option>
                <option value="5">学院5</option>
            </select></div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">部门：</label>
            <div class="layui-input-block"><input type="text" name="Tedit_department" id="Tedit_department"
                                                  lay-verify="department" class="layui-input"></div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">职位：</label>
            <div class="layui-input-block"><input type="text" name="Tedit_post" id="Tedit_post" lay-verify="post"
                                                  class="layui-input">
            </div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">联系方式：</label>
            <div class="layui-input-block"><input type="text" name="Tedit_tel" id="Tedit_tel" lay-verify="tel"
                                                  class="layui-input"></div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">邮箱：</label>
            <div class="layui-input-block"><input type="text" name="Tedit_email" id="Tedit_email" lay-verify="email"
                                                  class="layui-input">
            </div>
        </div>
        <div class="layui-col-lg2 layui-col-lg-offset5">
            <button class="layui-btn" name="account-Tedit-btn1" lay-submit lay-filter="tEdit">修改</button>
        </div>
    </form>
</div>
<%--弹出层--学生编辑页面--%>
<div class="layui-row" id="account-editStudent-box" style="margin: 20px;width:500px;height:400px;display: none">
    <form class="layui-form" action="" lay-filter="component-form-group" autocomplete="off">
        <div class="layui-form-item">
            <label class="layui-form-label">学号：</label>
            <div class="layui-input-block"><input type="text" name="Sedit_sNO" id="Sedit_sNO" lay-verify="sNO"
                                                  class="layui-input"></div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">密码：</label>
            <div class="layui-input-block"><input type="text" name="Sedit_password" id="Sedit_password"
                                                  lay-verify="password" class="layui-input"></div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">真实姓名：</label>
            <div class="layui-input-block"><input type="text" name="Sedit_name" id="Sedit_name" lay-verify="name"
                                                  class="layui-input">
            </div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">性别：</label>
            <div class="layui-input-block">
                <input type="radio" name="Sedit_sex" value="男" title="男">
                <input type="radio" name="Sedit_sex" value="女" title="女">
            </div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">学院：</label>
            <div class="layui-input-block"><select name="Sedit_collName" id="Sedit_collName"
                                                   style="width: 140px;height: 40px;">
                <option value="测试学院">测试学院</option>
                <option value="学院2">学院2</option>
                <option value="学院3">学院3</option>
                <option value="学院4">学院4</option>
                <option value="学院5">学院5</option>
            </select></div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">专业：</label>
            <div class="layui-input-block"><input type="text" name="Sedit_majorName" id="Sedit_majorName"
                                                  lay-verify="major" class="layui-input"></div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">班级：</label>
            <div class="layui-input-block"><input type="text" name="Sedit_classes" id="Sedit_classes"
                                                  lay-verify="classes" class="layui-input"></div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">联系方式：</label>
            <div class="layui-input-block"><input type="text" name="Sedit_tel" id="Sedit_tel" lay-verify="tel"
                                                  class="layui-input"></div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">邮箱：</label>
            <div class="layui-input-block"><input type="text" name="Sedit_email" id="Sedit_email" lay-verify="email"
                                                  class="layui-input">
            </div>
        </div>
        <div class="layui-col-lg2 layui-col-lg-offset5">
            <button class="layui-btn" name="account-Sedit-btn1" lay-submit lay-filter="sEdit">修改</button>
        </div>
    </form>
</div>
<script src="js/account.js"></script>
</html>
